Filtering method and filter

ABSTRACT

The invention relates to a filtering method and a filter implementing the filtering method. In the solution, a signal is filtered by at least one real FIR filter having at least one stop frequency pair whose different frequencies are symmetrically on different sides of at least one alias frequency.

FIELD OF THE INVENTION

[0001] This application is a Continuation of International ApplicationPCT/FI01/00956 filed on the of Nov. 1, 2001 which designated the US andwas published under PCT Article 21(2) in English. The invention relatesto a filter for the decimation or interpolation of a digital signal.

BACKGROUND OF THE INVENTION

[0002] Digital signal processing comprises several applications in whichsampling should be changeable. In decimation, the sampling period isextended, whereby the sampling frequency decreases. This reduces thenumber of data points processed or stored in the memory per a time unit.In interpolation, the sampling period is shortened and the samplingfrequency increases and the number of data points per a time unitincreases.

[0003] There is a need to change sampling for instance in a radio systemreceiver in which an analogue-to-digital conversion is made to a passband signal using a high sampling frequency. After the A/D conversion,the frequency of the pass band signal is decreased to a base band, butthe sampling frequency still remains high. Sampling can be reduced byusing a decimation filter, which also improves the signal-to-noiseratio.

[0004] An example of an ordinary decimating or interpolating filter,which changes the sampling of a signal by a high coefficient, is forinstance a CIC (Cascaded Integrator-Comb) filter which comprises a setof integrators, a sampler and a set of comb filters after each other ina series. The solution is described in more detail in the publication:E. B. Hogenauer, An Economical Class of Digital Filters for Decimationand Interpolation, which is incorporated herein by reference.

[0005] A problem with the decimating and interpolating CIC filter isthat the stop band does not efficiently enough attenuate the interferingsignals. Especially if the stop band has interfering signals that arenot exactly on the notch frequency of the CIC filter, the interferencemay damage the operation of the filter.

BRIEF DESCRIPTION OF THE INVENTION

[0006] It is thus an object of the invention to provide an improvedmethod and a filter implementing the method so as to efficientlyattenuate interference on a wider frequency band. This is achieved by afiltering method in which a signal is processed digitally and samplingis changed by coefficient M which is a positive integer and whichdefines alias frequencies on the frequency band of the filtering method.In the method, the signal is further filtered by at least one real FIRfilter having at least one stop frequency pair whose differentfrequencies are symmetrically on different sides of at least one aliasfrequency.

[0007] The invention also relates to a filter which is adapted toprocess a signal digitally and comprises a sampler for changing samplingby coefficient M which is a positive integer and which defines aliasfrequencies on the frequency band of the filtering method. Further, thefilter comprises at least one real FIR filter having at least onecomplex stop frequency pair whose different frequencies aresymmetrically on different sides of at least one alias frequency.

[0008] Preferred embodiments of the invention are set forth in thedependent claims.

[0009] The invention is based on using two stop frequencies, instead ofjust one, per each alias frequency, the stop frequencies being generatedby a complex conjugate pair in a transfer function.

[0010] The solution of the invention provides several advantages. Thestop band can be made wider, which enables a more efficient interferenceelimination and a more reliable filter operation.

BRIEF DESCRIPTION OF THE FIGURES

[0011] The invention will now be described in greater detail by means ofpreferred embodiments and with reference to the attached drawings inwhich

[0012]FIG. 1 shows a CIC filter,

[0013]FIG. 2A shows a filter which comprises a second-order IIR filter,a sampler and a second-order FIR filter,

[0014]FIG. 2B shows a zero-pole map,

[0015]FIG. 2C shows the amplification of the disclosed filter and theCIC filter as a function of the frequency,

[0016]FIG. 2D shows a filter which comprises a CIC filter and asecond-order IIR filter and FIR filter on different sides of the CICfilter,

[0017]FIG. 2E shows a filter which comprises an integrator, asecond-order IIR filter, a sampler, a second-order FIR filter and a combfilter,

[0018]FIG. 3 shows a second-order decimator whose delay elements arereset regularly,

[0019]FIG. 4A shows a fourth order decimator whose delay elements arereset regularly,

[0020]FIG. 4B shows a general block diagram of a decimator whose delayelements are reset regularly, and

[0021]FIG. 5 shows a filter having two comb filters operationallyconnected to it.

DETAILED DESCRIPTION OF THE INVENTION

[0022] The described solution is suited for use in changing the samplingof a received signal in a radio system receiver without, however, beinglimited to it.

[0023] Let us first examine a prior-art CIC filter described by way of ablock diagram in FIG. 1. The CIC filter comprises N integrators 10 and Ncomb filters 12, wherein N is a positive integer. Each integrator can beshown by means of an adder 100 and a delay element 102. Each integratoradds a delayed signal to an incoming signal. The comb filter can also beshown by means of a delay element 106 and an adder 108. Each adder 108subtracts a delayed signal from an incoming signal. Between theintegrator block 10 and the comb filter block 12, there is a sampler 104which changes the sampling by coefficient M, M being a positive integer.When feeding a signal from left to right, the CIC filter of FIG. 1serves as a decimator. When feeding a signal from right to left, the CICfilter of FIG. 1 serves as an interpolator. When decimating, the CICfilter reduces the sampling frequency by coefficient M and wheninterpolating, it increases the sampling frequency by coefficient M. Thetransfer function H(z) of a decimating or interpolating filter is in itsz transformation form as follows:

H(z)=[(1−z ^(−m))/(1−z ⁻¹)]^(N),  (1)

[0024] wherein z is a frequency variable of z space, z⁻¹ represents aunit delay, M is a decimation coefficient, N is the number of order(number of integrators and comb-filtering stages). The zero points ofthe transfer function of the integrator 10 are the poles of the transferfunction of the filter. Thus, z=1 is an N-fold pole. The zero points ofthe transfer functions of the comb filters are zeros of the filter. Thisway, the zero point is z=^(M){square root}{square root over (1)}. Forinstance, when the sampling change is M=4, the zero points areZ_(1,2,3,4) =±1, ±j. The zero points of the filter are also N-fold.

[0025] Let us now examine a filter according to the solution describedin FIG. 2A, which filter is suited for both interpolation anddecimation. The samples propagate in the filter controlled by a clockand addition, subtraction and multiplication are usually done during oneclock cycle. The sampler 210 is as the sampler 104 in FIG. 1. In thissolution, however, the integrating block 10 of the CIC filter isreplaced by a second-order IIR filter 20 which comprises adders 200 and202, a multiplier 204, and delay elements 206 and 208. The filter canhave one or more blocks 20. In the adder 200, a signal delayed in thedelay elements 206 and 208 is subtracted from the incoming signal. Tothe thus obtained difference signal, a signal delayed in the delayelement 208 is added, the delayed signal having been multiplied in themultiplier 204 by coefficient 2·real(a), wherein a is a complexparameter of the filter. During decimation, this sum signal propagatestowards the sampler 210. During interpolation, the signal arriving atblock 20 comes from the sampler 210. The transfer function of block 20is

D(z)=(1−az ⁻¹)·(1−a*z ⁻¹)=1−2·real(a)z ⁻¹ +z ⁻²   (2)

[0026] The filter is real, because coefficients (1, 2·real(a) and 1) ofthe polynome are real. Correspondingly, the comb block 12 of the CICfilter is replaced by a second-order FIR filter which comprises delayelements 212 and 218, adders 214 and 220, and a multiplier 216. Thefilter has as many blocks 22 as blocks 20. In the adder 214, a signaldelayed in the delay element 212 is subtracted from the incoming signal,the delayed signal having been multiplied in the multiplier 216 bycoefficient 2·real(a^(M)), wherein a is a complex parameter of thefilter. In the adder 220, a signal delayed in the delay elements 212 and218 is added to the difference signal. During decimation, this signal isthe outgoing signal. During interpolation, the signal arriving at block22 is fed into the adder 220. The transfer function of block 22 is

L(z)=(1−(az ⁻¹)^(M))·(1−(a*z ⁻¹)^(M))=1−2·real(a ^(M))z ^(−M) +z^(−2M)  (3)

[0027] This filter, too, is real, because the coefficients of thepolynome are real. In formulas (2) and (3), a is a complex parameterwhich can be presented as a=α+jβ, wherein j is an imaginary unit, a* isthe complex conjugate a*=α−jβ of parameter a, and the absolute value ofparameter a and a* is 1, i.e. |a|=|a*|={square root}{square root over(α²+β²)}=1. Parameter a does not, however, obtain the value a=1.Coefficient real(a) preferably obtains the value${{{real}(a)} = {1 - \frac{1}{\,_{2}T}}},$

[0028] wherein T is a positive integer. In such a case, a isa=real(a)+j{square root}{square root over (1−[real(a)]²)}. To simplifythe multiplication, one should try to have as few ones as possible inthe binary format of parameter a.

[0029] In a decimating filter, the multiplier 216 can be implemented asa serial multiplier instead of an ordinary multiplier, because theproduct need not be formed at every clock cycle, but the multiplier 216has M clock cycles time to form the multiplication product before thenext sampling.

[0030] Let us now examine the effect of parameter a on the zero-pole mapof the complex frequency space by means of FIG. 2B. The vertical axis Imis imaginary and the horizontal axis Re is real. The frequency band usedin filtering, i.e. the operating band of the filter, corresponds to afull circle. Let us assume, for instance, that sampling is changed bycoefficient M=4. This produces four alias frequencies 252 and the entirecircle is divided into four sections. During decimation, all aliasfrequencies 252 fold on top of each other on the lowest operatingfrequency 250 of the [alias] filter on the positive real axis in thesame manner as all circle quarters fold on the first quarter. The lowestoperating frequency 250 of the filter is a DC component, for instance,i.e. the frequency 250 is 0 Hz. The alias frequency 252 having thehighest frequency is depicted at the same point as the lowest frequency250 of the filter. During decimation, the alias frequency 252 f_(alias)is f_(alias)=k·(f_(sample)/M), wherein k is k=[1, . . . , M]. Duringinterpolation, the corresponding alias frequency 252 on the positivereal axis multiplies into three other alias frequencies 252. Similarly,the first quarter multiplies into three other quarters. Duringinterpolation, the alias frequency is thus f_(alias)=(M−i)·f_(sample),wherein i is i=[0, . . . , M−1]. In the presented solution, parameter ais used to affect the filtering in such a manner that corresponding tothe alias frequencies 252, there are two complex frequencies 254 and 256derived from parameter a that are located symmetrically on differentsides of the alias frequencies 252 and that are stop frequencies offiltering. The complex frequencies 254 and 256 are also in the same wayon different sides of the lowest frequency 250 of the filter. Filteringamplification on these two stop frequencies is substantially zero, i.e.the transfer function obtains the value zero. Mathematically, this is:${H(z)} = {\frac{L(z)}{D(z)} = {{0\text{~~=>}{L(z)}} = {{\left( {1 - \left( {a\quad z^{- 1}} \right)^{M}} \right) \cdot \left( {1 - \left( {{a\quad}^{*}z^{- 1}} \right)^{M}} \right)} = 0.}}}$

[0031] The result is two times M zero points. For instance, if thesampling change coefficient M is M=4, the zero points are z₁=a, z₂=a*,z₃=exp(jπ/4)·a, z₄=exp(jπ/4)·a*, z₅=exp(jπ/2)·a, z₆=exp(jπ/2)·a*,z₇=exp(j3π/4)·a and z₈=exp(j3π/4)·a*, which are points 254 and 256 inFIG. 2B.

[0032] The poles of the transfer function of filtering are at the zeropoints of the denominator, i.e.D(z)=(1−az⁻¹)·(1−a*z⁻¹)=1−2·real(a)z⁻¹+z⁻²=0. The result is polefrequencies z=a and z=a* corresponding to the zero points, both beingsimple zero points on both sides of the lowest operating frequency 250of the filter.

[0033] Thus in the presented solution, there is a complex conjugate paira and a* for each alias frequency f_(alias) in such a manner that theaverage value of the complex conjugate pair corresponds to the aliasfrequency f_(alias) in the z frequency space. The complex conjugate paira and a* thus unambiguously defines the pole and stop frequencies of thefilter.

[0034]FIG. 2C shows a descriptor 260 of the transfer function of aconventional CIC filter and a descriptor 262 of the transfer function ofa filter according to the presented solution. The vertical axis showsfilter amplification A on a freely selected scale and the horizontalaxis shows frequency f. The CIC filter has only one stop frequency foreach alias frequency. In the presented solution, the use of at least onecomplex conjugate pair (FIG. 2C shows the impact of only one complexconjugate pair) produces at least two real stop frequencies 266 (FIG. 2Chas only two stop frequencies) for each alias frequency 264 and thewidening of the stop band, which improves the interference immunity ofthe filter, because even though the interference is not exactly on thealias frequency 264, it still attenuates strongly as long as it isbetween two stop frequencies (a small deviation outside the stopfrequency range is also possible). For instance GSM (Global System forMobile Communication) and WCDMA (Wide-band Code Division MultipleAccess) radio systems require a high attenuation of the interferencepower on a stop band, and high attenuation is possible with thepresented solution. Because two complex conjugate pairs widen the stopband, spurious frequencies can be easily attenuated to the extentrequired by a wide band.

[0035]FIGS. 2D and 2E show solutions in which the presented solution iscombined with a CIC filter known per se. The solution of FIG. 2Dcomprises at least one second-order IIR filter 20, at least one block10, a sampler 210, at least one block 12 and at least one second-orderFIR filter 22. The solution in FIG. 2E comprises at least one block 10,at least one second-order IIR filter 20, a sampler 210, at least onesecond-order FIR filter 22 and at least one block 12. The blocks canalso be arranged as follows: 10, 20, 210,12 and 22. The mutual order ofblocks 10 and 20 bears no significance to the solution, and neither doesthe mutual order of blocks 12 and 22.

[0036] In FIGS. 2D and 2E, there are as many blocks 12 as blocks 10.Similarly, there are as many blocks 20 as blocks 22. Further, blocks 10and 12 are the same as blocks 10 and 12 of FIG. 1. Correspondingly,blocks 20, 22 and 210 are the same as blocks 20, 22 and 210 of FIG. 2A.

[0037] The transfer function of the filter according to FIGS. 2D and 2Eis generally: $\begin{matrix}{{H(z)} = {{{R(z)}\frac{{L_{1}(z)}\quad \ldots \quad {L_{p}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}\quad o\quad r\quad {H(z)}} = {\frac{{L_{1}(z)}\quad \ldots \quad {L_{p}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}{R(z)}}}} & (4)\end{matrix}$

[0038] wherein the number p of terms is a positive integer and the termR(z) refers to the filter transfer function known per se. The transferfunction R(z) can for instance be the transfer function of the CICfilter. Each term D_(l)(z) refers to a second-order IIR filter (such asblock 20) and each term L_(l)(z) refers to a second-order FIR filter(such as block 22). In each block D_(l)(z) and L_(i)(z), the parameterof the filter is a_(l) which determines each zero and pole of thetransfer function. Parameter a_(i) of each block i differs fromparameters a_(j) of the other blocks, wherein j≠i. In addition, none ofparameters a is one, i.e. a₁ . . . a_(p)≠1, and the absolute value ofall parameters a is one, i.e. |a₁|≡ . . . ≡|a_(p)|≡1. The number p ofblocks D₁(z) . . . D_(p)(z) and L₁(z) . . . L_(p)(z) is at least one.

[0039] The filter transfer function which is${H(z)} = \frac{{L_{1}(z)}\quad \ldots \quad {L_{p}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}$

[0040] can be presented as H(z)=G(z). Similarly, the filter transferfunction which is${{H(z)} = {{{R(z)}\frac{{L_{1}(z)}\quad \ldots \quad {L_{p}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}\quad o\quad r\quad {H(z)}} = {\frac{{L_{1}(z)}\quad \ldots \quad {L_{p}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}{R(z)}}}},$

[0041] wherein R(z) is the transfer function of a known filteringmethod, can be presented as H(z)=R(z)G(z) or H(z)=G(z)R(z). The transferfunction R(z) can be CIC filtering or any other desired filtering. Inboth above cases, G(z) can be presented in a power series formG(z)=c(0)+ . . . +c(p)z^(−2pM). The serial-form term G(z) can beimplemented as a FIR filter, because coefficients c(i), wherein i=[1, .. . p], always unambiguously depend on parameter a and the complexconjugate a* of parameter a. For instance, coefficient c(0) is c(0)=1and coefficient c(p) is c(p)=(a₁a*₁)^(M)· . . . ·(a_(p)a*_(p))^(M).Especially if the transfer function${H(z)} = \frac{{L_{1}(z)}\quad \ldots \quad {L_{p}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}$

[0042] can be presented as${{H(z)} = {{G(z)} = \frac{\left( {L(z)} \right)^{p}}{\left( {D(z)} \right)^{p}}}},$

[0043] parameter a of all blocks L(z) and D(z) is the same, G(z) can bepresented as G(z)=1+ . . . +(aa*)^(pM)z^(−2pM). By implementing thepower series-form term G(z) as a FIR filter, the stability of the filterimproves. In addition, to simplify the multiplication, one should try tohave as few ones as possible in the binary format of coefficients c(0)to c(p). Coefficients c(0) to c(p) of the term G(z) can be non-integers.In the presented solution, a non-integer coefficient c(i) can be roundedto an integer. This simplifies the structure.

[0044] At least one zero pair in the term G(z) can also be left out, inwhich case the corresponding multiplication is not done or themultiplier implemented. This means that one of the transfer functionparts L_(l)(z) of the second-order FIR filter is not implemented. Thenat least one term L(z) of the second-order FIR filtering that is a pairof a term D(z) of the second-order IIR filtering is left out, and theterm G(z) is${G(z)} = \frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}$

[0045] wherein v is a positive integer with v<p. This can be doneespecially when the filter transfer function is H(z)=R(z)G(z), whereinR(z) alone already band-stop filters efficiently. This, too, simplifiesthe structure, because the number of FIR filter coefficients becomessmaller. After the term L_(i)(z) is removed, the weighting coefficientsof the taps of the term G(z), i.e. the values of parameters a and a*,can be altered in comparison with the original values to improvefiltering.

[0046] When implementing a decimator as presented herein, it ispossible, instead of each FIR block 22 shown in FIG. 2A, to use FIRfilters whose input signal is the input signal of the delay elements,and to reset the delay elements to zero at the sampling time of thesampler. Let us first examine the theoretical basis of this solution.The output signal Y(z) of the z variable of the filter in the frequencyspace is a product of the impulse response H(z) and the input signalX(z) of the filter: Y(z)=H(z)X(z). Adding to and subtracting from theinput signal one or more desired signals A(z) does not change the outputsignal Y(z). This means that${{Y(z)} = {{{H(z)}\left\lbrack {{X(z)} + {\sum\limits_{i = 0}^{W}{A_{i}(z)}} - {\sum\limits_{i = 0}^{W}{A_{i}(z)}}} \right\rbrack} = {{{H(z)}\left\lbrack {{X(z)} + {\sum\limits_{i = 0}^{W}{A_{i}(z)}}} \right\rbrack} - {{H(z)}{\sum\limits_{i = 0}^{W}{A_{i}(z)}}}}}},$

[0047] wherein W refers to the number of signals A(z) to be added. Theadded signal A(z) is preferably a reset signal of the delay elements 212and 218 that empties the content of the delay elements. This is shown inthe term${{H(z)}\left\lbrack {{X(z)} + {\sum\limits_{i = 0}^{W}{A_{i}(z)}}} \right\rbrack}.$

[0048] When the delay elements are reset to zero after each sampling,overload situations due to a possible DC offset are avoided and a morereliable operation achieved in all conditions. The impact of one or morereset signals A(z) is noted by the term${H(z)}{\sum\limits_{i = 0}^{W}{A_{i}(z)}}$

[0049] when forming the output signal Y(z). The term${H(z)}{\sum\limits_{i = 0}^{W}{A_{i}(z)}}$

[0050] can be implemented by a FIR filter.

[0051] A problem with a second-order IIR filter may be that the data fedinto it does not have zero as a long-term expected value, i.e. the datamay include DC offset. Already a small DC offset in the data causes anoverload in the second-order IIR filters and malfunction in thedecimating filter. To avoid DC offset, it is possible to use twoscomplement arithmetics or the like in which positive and negativenumbers are obtained from each other by a simple change of bit.Increasing the word length of the decimating filter can often alsoreduce the problem. The problem can, however, be eliminated by resettingthe delay elements to zero at every sampling, in which case DC offsetdoes not cause an overload. In addition, having the poles of the filteron a unit circle increases the instability of the filter, but resettingthe delay elements as described improves stability.

[0052]FIG. 3 shows as a block diagram the implementation of asecond-order decimator in which the delay elements are reset to zero atthe sampling time of the sampler. The solution comprises a second-orderIIR filter 300 corresponding to block 20 of FIG. 2A. Block 300 comprisesadders 302 and 304, a multiplier 306 and delay elements 308 and 310. Inaddition, instead of block 22 of FIG. 2A, the solution comprises FIRfilters 316 and 318 and an adder 320 in block 322. The solution alsocomprises samplers 312 and 314 that decimate by coefficient M. When thesamplers 312 and 314 sample signals to be fed into the delay elements308 and 310, the content of the delay element 308 is at the same timereset to zero by a signal A₁(z) and the content of the delay element 310is reset to zero by a signal A₂(z). The sample of the samplers 312 and314 is fed to the FIR filters 316 and 318, the FIR filter 316 having atransfer function H_(FIR1)(z) of H_(FIR1)(z)=−H(z) A₁(z) and the FIRfilter 318 having a transfer function H_(FIR2)(z) of H_(FIR2)(z)=−H(z)A₂(z). The output signals of the FIR filters 316 and 318 are summed inthe adder 320, whereby the output signal of the filter is formed.

[0053]FIG. 4A shows a block diagram of a fourth-order decimator, theprinciple of which can also easily be used for higher-order decimators.The decimator comprises two second-order IIR filters 400, samplers 404to 410 that decimate by coefficient M, FIR filters 412 to 418, adders420 and 422, a second-order FIR filter 402 and an adder 426. Thesecond-order IIR filter 400 comprises adders 430 and 432, a multiplier434 and delay elements 436 and 438. The second-order IIR filter 402comprises adders 440 and 442, a multiplier 444 and delay elements 446and 448. The second-order FIR filter 424 comprises delay elements 450and 456, adders 454 and 458 and a multiplier 452 whose coefficient 2real(a₁ ^(M)) depends on coefficient 2real(a₁) of the IIR filter 400.The operation of the second-order FIR filter 424 can be located in theFIR blocks 412 and 414 and block 424 need not be implemented separately.

[0054]FIG. 4B shows a general block diagram of a decimator of a higherorder than the second order. The decimator comprises a second-orderfilter 470 which comprises blocks 300, 312, 314 and 322 as in FIG. 3. Inaddition, the decimator comprises at least one second-order filter 472.For each second-order IIR filter unit 474, the decimator comprisessamplers 476 and 478 and a block 480 (block 480 is similar to block322), one second-order FIR filter 482 and an adder 484 in block 472. Theadder 484 sums the signal arriving from the second-order FIR filter 482with the signal arriving from block 480. In this solution, too, theoperation of the second-order FIR filter 482 can be combined with theFIR blocks of the previous order (if the previous order is block 470,the FIR block 482 can be combined with block 322) as shown in thesolution of FIG. 4A.

[0055] In the presented solution, two extra comb filter blocks can yetbe added to the end of the decimator or to the beginning of theinterpolator. Such a solution is shown in FIG. 5. The filter comprises ablock 500, which is a prior-art CIC filter or a filter block accordingto FIGS. 2A, 2C, 2D, 3A or 3B, and at least one comb filter pair 502 and504 whose operation is affected by parameter b. In the comb filter 502,a signal delayed by the delay element 506 is multiplied in themultiplier 508 by coefficient 1/b and the result is subtracted in theadder 510 from a signal received by it. In the second comb filter 504,the signal delayed by the delay element 512 is multiplied in themultiplier 514 by coefficient b and the result is subtracted in theadder 516 from a signal received by it. The following applies toparameter b: b is real, the value of parameter b is positive and unequalto 1. When using the comb blocks 502 and 504 in filtering, the filteringkeeps the linear phase properties of the signal and the ripple of theamplification of the pass band decreases.

[0056] Let us yet shortly examine the FIR and IIR filters. In timespace, the output y(n) of a K-tap FIR filter can be presented as$\begin{matrix}{{{y(n)} = {\sum\limits_{k = 0}^{K - 1}{{h(k)} \times \left( {n - k} \right)}}},} & (5)\end{matrix}$

[0057] wherein h(k) is a tap coefficient and k is the sample index.Correspondingly, the output of an IIR filter is $\begin{matrix}{{y(n)} = {\sum\limits_{k = 0}^{\infty}{{h(k)} \times \left( {n - k} \right)}}} & (6)\end{matrix}$

[0058] which shows that a fed impulse affects the output for anindefinite time.

[0059] Even though the invention has been explained in the above withreference to examples in accordance with the attached drawings, it isclear that the invention is not restricted to them but can be modifiedin many ways within the scope of the inventive idea disclosed in theattached claims.

1. A filtering method, the method comprising processing a signaldigitally, changing sampling by coefficient M which is a positiveinteger and which defines alias frequencies on the frequency band of thefiltering method, filtering the signal by at least one real FIRfiltering having at least one stop frequency pair whose differentfrequencies are symmetrically on different sides of at least one aliasfrequency.
 2. A method as claimed in claim 1, filtering the signal withat least one real IIR filtering, and changing the sampling bycoefficient M between the IIR filtering and the FIR filtering.
 3. Amethod as claimed in claim 1, filtering the signal with at least on realFIR filtering and at least one real IIR filtering in such a manner thatthe transfer function H(z) of the filtering method comprises a quotientof at least one second-order IIR filtering D(z) and at least onesecond-order FIR filtering L(z) which is$\frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}},$

 wherein p and v are positive integers, and changing the sampling bycoefficient M between the IIR filtering and the FIR filtering.
 4. Amethod as claimed in claim 1, wherein the transfer function of the FIRfiltering comprises a term L(z) describing the second-order FIRfiltering that is L(z)=(1−(az⁻¹)^(M))·(1−(a^(*)z⁻¹)^(M)), and a and a*are complex parameters of the filter, the absolute value of each is 1and they define the stop frequencies of the FIR filtering, and a* is acomplex conjugate of parameter a.
 5. A method as claimed in claim 2,wherein each IIR filtering has, corresponding to the lowest operatingfrequency of the filter, at least one complex pole frequency pair whosedifferent frequencies are symmetrically on different sides of the lowestoperating frequency of the filter, each IIR filtering is the pair of oneFIR filtering in such a manner that the IIR filtering and the FIRfiltering have the same filtering parameters a and a* that define thestop and pole frequency pairs of said IIR and FIR filterings, and a anda* are complex parameters of the filter, the absolute value of each is 1and a* is a complex conjugate of parameter a.
 6. A method as claimed inclaim 3, performing the IIR filtering as second-order IIR filtering andperforming the FIR filtering as second order FIR filtering, and eachsecond-order IIR filtering is the pair of one second-order FIR filteringin quotient$\frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}$

in such a manner that the IIR filtering and the FIR filtering have thesame filtering parameters a and a* and there are as many second-orderFIR terms L(z) as second-order IIR terms D(z), in which case v=p appliesto the indexes p and v, and performing the second-order FIR filtering insuch a manner that the transfer function L(z) of the second-order FIRfiltering is L(z)=(1−(az⁻¹)^(M))·(1−(a^(*)z⁻¹)^(M)), and performing thesecond-order IIR filtering in such a manner that the transfer functionD(z) of the IIR filtering i corresponding to the second order isD(z)=(1−(az⁻¹)·(1−(a^(*)z⁻¹), wherein a and a* are complex parameters ofthe filter, the absolute value of each is 1 and they define the stop andpole frequency, and a* is a complex conjugate of parameter a.
 7. Amethod as claimed in claim 4, wherein the real part of parameter a is${1 - \frac{1}{\,_{2}T}},$

and T is a positive integer.
 8. A method as claimed in claim 3,performing the filtering by a filtering method which comprises both apre-defined filtering whose transfer function is R(z) and a filteringwhich is in quotient format$\frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}},$

and the transfer function describing the filtering method is${{H(z)} = {{{R(z)}\frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}\quad o\quad r\quad {H(z)}} = {\frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}{R(z)}}}},$

 wherein the second-order FIR filtering term L_(l)(z) isL_(i)(z)=(1−(a₁z⁻¹)^(M))·(1−(a^(*) ₁z⁻¹)^(M)) and the second-order IIRfiltering term D_(l)(z) is D_(i)(z)=(1−a₁z⁻¹)·(1−a*_(i)z⁻¹), wherein iis the filtering index, p is a positive integer and a, is a complexparameter of the filter, the absolute value of which is 1 and whichdefines the stop and pole frequency, and a*₁ is a complex conjugate ofparameter a_(i).
 9. A method as claimed in claim 3, performing thefiltering by a filtering method which comprises a transfer function ofG(z)=c(0)+ . . . +c(p)z^(−2pM) that is formed as a quotient${G(z)} = \frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}$

of products L₁(z)· . . . ·L_(p)(z) and D₁(z)· . . . ·D_(p)(z), andperforming the filtering according to the term G(z) as FIR filtering,wherein the term L_(l)(z) of the second-order FIR filtering isL_(l)(z)=(1−(a_(i)z⁻¹)^(M))·(1−(a^(*) _(l)z⁻¹)^(M)) and the termD_(l)(z) of the second-order IIR filtering isD_(i)(z)=(1−a_(l)z⁻¹)·(1−a^(*) _(i)z⁻¹), wherein i is the filteringindex, p is a positive integer and a_(i) is a complex parameter of thefilter, the absolute value of which is 1 and which defines the stop andpole frequency, and a* is a complex conjugate of parameter a.
 10. Amethod as claimed in claim 9, wherein at least one non-integercoefficient is rounded to an integer when one or more coefficients c(0)to c(p) are other than integers.
 11. A method as claimed in claim 3,leaving out of the filtering at least one term L(z) of the second-orderFIR filtering, which is the pair of a second-order IIR filtering D(z),whereby the term G(z) is${{G(z)} = \frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}},$

wherein v<p applies.
 12. A method as claimed in claim 2, wherein thefiltering method being a decimating method, resetting the delay elementsof each IIR filtering to zero when a decimated sample is taken, changingthe sampling by decimating signals delayed in IIR filtering, andfiltering the decimated signal by FIR filtering.
 13. A method as claimedin claim 1, performing also at least two comb filterings which form acomb filtering pair and which have a common parameter b affecting thefiltering operation in such a manner that the transfer function of thefirst filtering of the comb filtering pair obtains as its zero point thevalue b which is the stop frequency of the first comb filtering, and thetransfer function of the second filtering of the comb filtering pairobtains as its zero point the value 1/b which is the stop frequency ofthe second comb filtering and wherein b is real, positive and unequalto
 1. 14. A filter which is arranged to process a signal digitally andcomprises a sampler for changing sampling by coefficient M which is apositive integer and which defines alias frequencies on the frequencyband of the filtering method, wherein the filter comprises at least onereal FIR filter having at least one complex stop frequency pair whosedifferent frequencies are symmetrically on different sides of at leastone alias frequency.
 15. A filter as claimed in claim 14, wherein thefilter comprises at least one real IIR filter, and the sampler isoperationally between the IIR filter and the FIR filter.
 16. A filter asclaimed in claim 14, wherein the filter comprises at least one real FIRfilter and the filter comprises at least one real IIR filter and thetransfer function H(z) of the filter comprises a quotient of at leastone second-order IIR filter D(z) and at least one second-order FIRfilter L(z) which is$\frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}},$

 wherein p and v are positive integers.
 17. A filter as claimed in claim14, wherein the transfer function of the FIR filter comprises a termL(z) describing the second-order FIR filtering that isL(z)=(1−(az⁻¹)^(M))·(1−(a^(*)z⁻¹)^(M)), wherein a and a* are complexparameters of the filter, the absolute value of each is 1 and theydefine the stop frequency, and a* is a complex conjugate of parameter a.18. A filter as claimed in claim 15, wherein each IIR filter has,corresponding to the lowest operating frequency of the filter, at leastone complex pole frequency pair whose different frequencies aresymmetrically on different sides of the lowest operating frequency ofthe filter, and each IIR filter is the pair of one FIR filter in such amanner that the IIR filter and the FIR filter have the same filteringparameters a and a* that define the stop and pole frequency pairs ofsaid IIR and FIR filters, and a and a* are complex parameters of thefilter, the absolute value of each is 1, and a* is a complex conjugateof parameter a.
 19. A filter as claimed in claim 16, wherein the IIRfilter is a second-order IIR filter and the FIR filter is a second-orderFIR filter, and each second-order IIR filter is the pair of onesecond-order FIR filter in such a manner that the IIR filter and the FIRfilter have the same filtering parameters a_(i) and a*_(i), and thetransfer function L_(i)(z) of the second-order FIR filter isL_(l)(z)=(1−(a_(l)z⁻¹)^(M))·(1−(a^(*) _(i)z⁻¹)^(M)), the transferfunction D_(i)(z) of the second-order IIR filter i isD_(l)(z)=(1−a_(l)z⁻¹)·(1−a^(*) _(i)z⁻¹), wherein a and a* are complexparameters of the filter, the absolute value of each is 1, and theydefine the stop and pole frequency, and a* is a complex conjugate ofparameter a.
 20. A filter as claimed in claim 17, wherein the real partof parameter a is ${1 - \frac{1}{\,_{2}T}},$

wherein T is a positive integer.
 21. A filter as claimed in claim 16,wherein the filter comprises both a desired filter part having atransfer function of R(z) and a filter part having a transfer functionof$\frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}},$

and the transfer function of the filter is${{H(z)} = {{{R(z)}\frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}\quad o\quad r\quad {H(z)}} = {\frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}{R(z)}}}},$

 wherein the term L_(i)(z) of the second-order FIR filtering isL_(l)(z)=(1−(a_(i)z⁻¹)^(M))·(1−(a^(*) _(i)z⁻¹)^(M)) and the termD_(i)(z) of the second-order IIR filtering isD_(l)(z)=(1−a_(i)z⁻¹)·(1−a^(*) _(l)z⁻¹), wherein p is a positive integerand a_(l) is a complex parameter of the filter, the absolute value ofwhich is 1 and which defines the stop and pole frequency, and a* is acomplex conjugate of parameter a.
 22. A filter as claimed in claim 16,wherein the transfer function of the filter comprises the termG(z)=c(0)+ . . . +c(p)z^(−2pM) that is formed as a quotient${G(z)} = \frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}$

of products L₁(z) . . . L_(p)(z) and D₁(z) . . . D_(p)(z), and thefilter is arranged to perform the filtering according to the term G(z)as FIR filtering, wherein the term L_(l)(z) of FIR filteringcorresponding to the second order isL_(l)(z)=(1−(a_(i)z⁻¹)^(M))·(1−(a^(*) _(l)z⁻¹)^(M)) and the termD_(l)(z) of IIR filtering corresponding to the second order isD_(i)(z)=(1−a_(l)z⁻¹)·(1−a^(*) _(i)z⁻¹), wherein p is a positive integerand a_(i) is a complex parameter of the filter, the absolute value ofwhich is 1 and which defines the stop and pole frequency, and a* is acomplex conjugate of parameter a.
 23. A filter as claimed in claim 22,wherein when one or more coefficients c(0) to c(p) are other thanintegers, at least one non-integer is rounded to an integer.
 24. Afilter as claimed in claim 16, wherein at least one second-order FIRfilter term L(z), which is the pair of a second-order IIR filter D(z),is left out of the filter, whereby the term G(z) is${{G(z)} = \frac{{L_{1}(z)}\quad \ldots \quad {L_{v}(z)}}{{D_{1}(z)}\quad \ldots \quad {D_{p}(z)}}},$

wherein v<p applies.
 25. A filter as claimed in claim 14, wherein whenthe filter is a decimator, the filter is arranged to reset to zero thedelay elements of each IIR filter when a decimated sample is taken, andthe samplers are arranged to take a sample for decimation from the inputsignal of the delay elements of the IIR filter, and the filter isarranged to FIR-filter the decimated signal.
 26. A filter as claimed inclaim 14, wherein the filter also comprises at least two comb filterswhich form a comb filter pair and which have a common parameter baffecting the filtering operation in such a manner that the transferfunction of the first filter of the comb filter pair obtains as its zeropoint the value b which is the stop frequency of the first comb filter,and the transfer function of the second filter of the comb filter pairobtains as its zero point the value 1/b which is the stop frequency ofthe second comb filtering, wherein b is real, positive and unequal to 1.